package com.hongling.uc;

import com.hongling.uc.ons.consumer.MyMessageConsumer;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cache.annotation.EnableCaching;

@SpringBootApplication
//配置扫描mapper接口的地址
@MapperScan(basePackages = {"com.hongling.uc.dao"})
//开启缓存机制
@EnableCaching
public class UcServiceApplication {

	public static void main(String[] args) {
		SpringApplication.run(UcServiceApplication.class, args);
		new MyMessageConsumer().subscribe(); // 系统启动的时候启动订阅
	}

}
